/*!
 * Copyright (c) 2020 the original author or authors
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
 * or implied. See the License for the specific language governing
 * permissions and limitations under the License.
 */

@import 'media.scss';

$width-container: 420px;
$min-width-container: 320px;
$padding-RL: 32px;
$padding-container: 49px $padding-RL;
$font-size-link: 12px;

@mixin reset-form-card() {
  .mat-card-content,
  .mat-card-actions,
  .mat-card-title {
    padding: 0 !important;
    margin: 0 !important;
  }

  ::ng-deep .mat-card-header-text {
    margin: 0 !important;
  }
}

@mixin form-btn() {
  width: 100%;
  padding: 12px 0;
  line-height: 22px;
}

@mixin form-wrapper() {
  width: 100%;
  max-width: $width-container;
  min-width: $min-width-container;
  text-align: center;
}

@mixin form-card() {
  @include reset-form-card();
  padding: $padding-container !important;

  @include mobile-portrait {
    padding: 34px 24px !important;
  }

  .form-card {
    &--logo {
      display: flex;
      justify-content: center;
      margin-bottom: 32px;

      img {
        min-width: 320px;
      }
    }

    &--title {
      margin-bottom: 19px;
    }

    &--form {
      margin-bottom: 6px;
      display: flex;
      flex-direction: column;
      width: 100%;
    }

    &--btn-wrapper {
      text-align: center;

      .btn {
        @include form-btn();
      }

      .link {
        margin-top: 16px;
        font-size: $font-size-link;
      }
    }
  }
}
